home *** CD-ROM | disk | FTP | other *** search
/ PC Professionell 2004 March / PCpro_2004_03.ISO / files / remoteIC / Tools / Microsoft / MSDE 2000 en / Install.cmd next >
Encoding:
Text File  |  2004-01-12  |  6.3 KB  |  119 lines

  1. @echo off
  2. set adminPassword=remoteic
  3. if not "%1"=="" set adminPassword=%1
  4. set installLog=C:\MSDEremoteIC.log
  5. set realOs=NT
  6. set language=English
  7. ::set language=Deutsch
  8. if not exist "%~pd0.\Data\Setup.exe" (echo Setup.exe could not be found in %~pd0Data) && (pause) && (goto :EOF)
  9. if not exist "%~pd0.\Data\setup.ini" (echo setup.ini could not be found in %~pd0Data) && (pause) && (goto :EOF)
  10. if not exist "%~pd0.\Data\remoteIC.exe" (echo remoteIC.exe could not be found in %~pd0Data) && (pause) && (goto :EOF)
  11. if not exist "%windir%\system32\findstr.exe" goto NOFINDSTR
  12. :: get os version
  13. ver | findstr "2000" >NUL
  14. if not errorlevel 1 set realOs=2000
  15. ver | findstr "XP" >NUL
  16. if not errorlevel 1 set realOs=XP
  17. :NOFINDSTR
  18. echo *********************************************************************
  19. echo *                                                                   *
  20. echo *   Microsoft SQL Server Desktop Engine 2000 (MSDE) %language%         *
  21. echo *                                                                   *
  22. echo *********************************************************************
  23. echo.
  24. echo.
  25. if not "%realOs%"=="NT" goto CONTINUEINSTALL
  26. if not "%adminPassword%"=="remoteic" goto CONTINUEINSTALL
  27. if "%language%"=="English" echo Syntax: %0 [password]
  28. if "%language%"=="English" echo.
  29. if "%language%"=="English" echo         [password]    Password of database administrator 'sa'
  30. if "%language%"=="English" echo                       Default password: '%adminPassword%'
  31. if "%language%"=="Deutsch" echo Syntax: %0 [kennwort]
  32. if "%language%"=="Deutsch" echo.
  33. if "%language%"=="Deutsch" echo         [kennwort]    Kennwort des Datenbankadministrators 'sa'
  34. if "%language%"=="Deutsch" echo                       Standard-Kennwort: '%adminPassword%'
  35. echo.
  36. echo.
  37. :CONTINUEINSTALL
  38. if "%language%"=="English" echo Hereby you accept the Microsoft license agreement in the file license.txt
  39. if "%language%"=="English" echo Do you want to start the installation of MSDE?
  40. if "%language%"=="Deutsch" echo Hiermit akzeptieren Sie die Microsoft Lizenzbedingungen in der Datei license.txt
  41. if "%language%"=="Deutsch" echo Moechten Sie die Installation von MSDE starten?
  42. echo.
  43. if "%language%"=="English" echo Press any key to continue or (Ctrl) (Break) to cancel.
  44. if "%language%"=="Deutsch" echo Druecken Sie eine beliebige Taste um fortzusetzen
  45. if "%language%"=="Deutsch" echo oder (Ctrl) (Break) um abzubrechen.
  46. pause>nul
  47. if not "%realOs%"=="NT" goto PASSWORD
  48. goto STARTINSTALL
  49. :PASSWORD
  50. cls
  51. echo *********************************************************************
  52. echo *                                                                   *
  53. echo *   Microsoft SQL Server Desktop Engine 2000 (MSDE) %language%         *
  54. echo *                                                                   *
  55. echo *********************************************************************
  56. echo.
  57. echo.
  58. if "%language%"=="English" echo Please enter a strong password for the database administrator 'sa'.
  59. if "%language%"=="Deutsch" echo Bitte geben Sie ein Kennwort fuer den Datenbank Administratior 'sa' ein.
  60. echo.
  61. if "%language%"=="English" echo Password:
  62. if "%language%"=="Deutsch" echo Kennwort:
  63. set adminPassword=
  64. set /P adminPassword=
  65. if "%adminPassword%"=="" goto PASSWORD
  66.  
  67. :STARTINSTALL
  68. cls
  69. echo *********************************************************************
  70. echo *                                                                   *
  71. echo *   Microsoft SQL Server Desktop Engine 2000 (MSDE) %language%         *
  72. echo *                                                                   *
  73. echo *********************************************************************
  74. echo.
  75. echo.
  76. if "%language%"=="English" echo The password of the database admin 'sa' will be set to '%adminPassword%'.
  77. if "%language%"=="English" echo Later this password will be used to create the remoteIC database.
  78. if "%language%"=="Deutsch" echo Das Kennwort des DB Administrators 'sa' wird auf '%adminPassword%' gesetzt'.
  79. if "%language%"=="Deutsch" echo Das Kennwort wird spaeter fuer die Erstellung der remoteIC Datenbank benoetigt.
  80. echo.
  81. pause
  82. cls
  83. echo *********************************************************************
  84. echo *                                                                   *
  85. echo *   Microsoft SQL Server Desktop Engine 2000 (MSDE) %language%         *
  86. echo *                                                                   *
  87. echo *********************************************************************
  88. echo.
  89. echo.
  90. if "%language%"=="English" echo Unattended install for MSDE is starting...
  91. if "%language%"=="Deutsch" echo Die automatische Installation wird nun gestartet...
  92. echo.
  93. if "%language%"=="English" echo Installation will be logged to %installLog%.
  94. if "%language%"=="Deutsch" echo Die Installation wird im Verzeichnis %installLog% protokolliert.
  95. echo.
  96. start "MSDE Installation" "%~pd0.\Data\Setup.exe" /settings "%~pd0.\Data\setup.ini" SAPWD="%adminPassword%" /L*v "%installLog%"
  97. if "%language%"=="English" echo Waiting for MSDE Setup to finish (approximately 5-10 minutes)...
  98. if "%language%"=="Deutsch" echo Warten auf Installationensende (Dauer ca. 5-10 Minuten)...
  99. echo.
  100. "%~pd0.\Data\remoteIC.exe" waitForReg HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{E09B48B5-E141-427A-AB0C-D3605127224A}" "DisplayName" "Microsoft SQL Server Desktop Engine (REMOTEIC)" /t:600
  101. if not "%errorlevel%"=="0" (echo Could not install MSDE) && (notepad "%installLog%") && (pause) && (goto :EOF)
  102. if "%language%"=="English" echo MSDE successfully installed.
  103. if "%language%"=="Deutsch" echo MSDE erfolgreich installiert.
  104. echo.
  105. pause
  106. echo.
  107. if "%language%"=="English" echo Try to start 'MSSQL$REMOTEIC' service...
  108. if "%language%"=="Deutsch" echo Starte 'MSSQL$REMOTEIC' Dienst...
  109. net start MSSQL$REMOTEIC
  110. if not "%errorlevel%"=="0" (echo Could not start service 'MSSQL$REMOTEIC') && (notepad "%installLog%") && (pause) && (goto :EOF)
  111. if "%language%"=="English" echo Now, install and start rICadmin and create the remoteIC database using the
  112. if "%language%"=="English" echo following database server name: %COMPUTERNAME%\REMOTEIC
  113. if "%language%"=="Deutsch" echo Installieren Sie nun rICadmin und erstellen Sie die remoteIC Datenbank
  114. if "%language%"=="Deutsch" echo mit folgendem Datenbank Server: %COMPUTERNAME%\REMOTEIC
  115. echo.
  116. pause
  117.  
  118.  
  119.